From 3e49205c7a0d947e5a9c37fabee4df1ae07d3135 Mon Sep 17 00:00:00 2001 From: Keir Fraser Date: Fri, 18 Jan 2008 22:27:51 +0000 Subject: [PATCH] xend: Handle unspecified timer_mode domain platform parameter. Signed-off-by: Keir Fraser --- tools/python/xen/xend/XendDomainInfo.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tools/python/xen/xend/XendDomainInfo.py b/tools/python/xen/xend/XendDomainInfo.py index 7a8081c030..f504e9cf89 100644 --- a/tools/python/xen/xend/XendDomainInfo.py +++ b/tools/python/xen/xend/XendDomainInfo.py @@ -1650,9 +1650,10 @@ class XendDomainInfo: self._recreateDom() # Set timer configration of domain - if hvm: + timer_mode = self.info["platform"].get("timer_mode") + if hvm and timer_mode is not None: xc.hvm_set_param(self.domid, HVM_PARAM_TIMER_MODE, - long(self.info["platform"].get("timer_mode"))) + long(timer_mode)) # Set maximum number of vcpus in domain xc.domain_max_vcpus(self.domid, int(self.info['VCPUs_max'])) -- 2.30.2